package com.hryk.medical.common.network;

import com.baoteng.network.callback.StringCallback;
import com.baoteng.network.executor.HttpExecutor;
import com.hryk.medical.common.model.Constants;

import java.util.HashMap;
import java.util.Map;

/**
 * Author: loren
 * Date: 2019/9/24
 */
public class RequestManager {

    private static String getPreUrl() {
        return "";
    }

    /**
     * 登录
     */
    public static void login(String name, String pwd, StringCallback callback) {
        String url = getPreUrl() + Constants.NetWork.LOGIN;
        Map<String, Object> params = new HashMap<>();
        params.put("uname", name);
        params.put("password", pwd);
        HttpExecutor.getDefault().postString(url, params, callback);
    }

}
